<?php
namespace app\home\controller;
use think\Db;
use think\captcha\Captcha;
use think\Loader;
class Topic extends \think\Controller{
    public function topic(){
        $id=$_GET['id'];
        $reslist=db('topic')->where('id',$id)->select();
        $this->assign('reslist',$reslist);
        return $this->fetch('topic');//继承基类的控制器 
    }
}